﻿using System;

namespace Ndmx.Framework.Common
{
    public class DataHandlerFactory : Factory
    {
        public DataHandlerFactory(Type type, String prefix) : base(type, prefix)
        {
            //
        }

        public DataHandler create(String entityName, String entityNamespace, String masterNamespace)
        {
            DataHandler dataHandler = null;
            dataHandler = (DataHandler)base.create(entityName, masterNamespace);
            dataHandler.entityName = entityName;
            dataHandler.entityNamespace = entityNamespace;
            dataHandler.masterNamespace = masterNamespace;
            dataHandler.init();
            return dataHandler;
        }
    }
}
